/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package matching.triple;

import matching.Restriction;
import matching.path.Path;
import ontology.Ontology;
import org.semanticweb.owl.model.OWLClass;

/**
 *
 * @author livia
 */
public abstract class PropertyTriple implements Triple{
	
	Restriction restriction;
	OWLClass context;
        Ontology onto;
	private Path path;
        //private OWLDataProperty funcInverse;


	PropertyTriple(Restriction r, OWLClass c, Ontology onto) {
		restriction=r;
		context=c;
                this.onto = onto;
	}

	@Override
	public abstract boolean equals(Triple t);

	@Override
	public OWLClass getContext() {
		return context;
	}

	public Restriction getRestriction() {
		return restriction;
	}

	@Override
	public abstract Object getElement();	

	@Override
	public boolean isClass() {
		return false;
	}

        public void setPath(Path p){
            //if(p.getInitialClass().equals(context))
                path=p;
        }

        public void set(Path p){
            this.path=p;
        }

        public Path getPath(){
            return path;
        }

        public boolean hasPath(){
            return path!=null;
        }

       /* public OWLDataProperty getFuncInverse() {
            return funcInverse;
        }

        public void setFuncInverse(OWLDataProperty funcInverse) {
            this.funcInverse = funcInverse;
        }*/
}
